home *** CD-ROM | disk | FTP | other *** search
- /* NCommPollCurrent.thor by Troels Walsted Hansen
- ** $VER: NCommPollCurrent.thor v1.06 (01.11.94)
- **
- ** An ARexx script that automates NComm dialing of the
- ** currently hi-lighted BBS (in the Startup Window) or
- ** the currently open BBS.
- **
- ** IMPORTANT: To use this script, the BBSs configured in THOR must
- ** have the same name as those in your NComm phonebook.
- **
- ** New: No new features for 1.06.
- */
-
- options results
-
- /* needs THOR functions */
-
- p = ' ' || address() || ' ' || show('P',,)
- thorport = pos(' THOR.',p)
-
- if thorport > 0 then thorport = word(substr(p,thorport+1),1)
- else
- do
- say 'No THOR port found!'
- exit 10
- end
-
- address(thorport)
- CURRENTBBS stem CURRENT
-
- /* Is NComm already running? If not, start it... */
-
- if ~show('p', 'ncomm') then
- do
- if ~exists("t:NCommStartupScript") then
- do
- call open(nscript, "t:NCommStartupScript", W)
- call writeln(nscript, "stack 10000")
- call writeln(nscript, "cd NComm:")
- call writeln(nscript, "run <>nil: NComm")
- call close(nscript)
- end
-
- address command
- "execute >nil: t:NCommStartupScript"
- "WaitForPort ncomm"
- if(rc) then exit
- end
-
- address 'ncomm'
- NCOMMTOFRONT
- DIAL CURRENT.BBSNAME
- exit
-